Skip to content

Conversation

continue[bot]
Copy link
Contributor

@continue continue bot commented Sep 22, 2025

Problem

When highlighting code and pressing cmd+I to start Edit mode, pressing / only shows "Explore prompts" as if there are no prompts available. However, in Chat mode, pressing / correctly shows all available prompts and slash commands.

Solution

Fixed the slash command filtering logic in Edit mode to allow prompt-based commands while still filtering out inappropriate built-in legacy commands.

Changes:

  • Modified ContinueInputBox.tsx: Added whitelist of allowed slash command sources for Edit mode
  • Modified selector: Extended to include source property in slash command data
  • Extended types: Added optional source property to ComboBoxItem interface

Allowed sources in Edit mode:

  • yaml-prompt-block - YAML prompt blocks
  • mcp-prompt - MCP server prompts
  • prompt-file-v1 & prompt-file-v2 - Prompt files
  • invokable-rule - Invokable rules

Filtered out in Edit mode:

  • built-in-legacy commands like /commit, /share, etc.

Result

Edit mode now properly shows relevant prompts when pressing / instead of just "Explore prompts", making it consistent with Chat mode behavior for prompt-based slash commands.

Testing

The filtering logic has been implemented with proper TypeScript types and follows the same pattern as context provider filtering. The whitelist approach ensures only appropriate command sources are shown in Edit mode.


Summary by cubic

Enabled prompt-based slash commands in Edit mode by whitelisting allowed sources and filtering out built-in legacy commands. Pressing / in Edit now shows relevant prompts, matching Chat mode.

  • Bug Fixes
    • Whitelist in ContinueInputBox for: yaml-prompt-block, mcp-prompt, prompt-file-v1/v2, invokable-rule.
    • Added source to ComboBoxItem and passed it through the selector for filtering.
    • Replaced “hide all commands in Edit” with selective filtering.

…out built-in legacy commands

- Add source property to ComboBoxItem interface to track command origin
- Update selector to include source in slash command data
- Implement whitelist-based filtering for Edit mode:
  - Allow: yaml-prompt-block, mcp-prompt, prompt-file-v1/v2, invokable-rule
  - Filter out: built-in-legacy commands like /commit, /share, etc.
- Replace complete removal of slash commands with selective filtering

Generated with [Continue](https://continue.dev)

Co-Authored-By: Continue <[email protected]>
@continue continue bot requested a review from a team as a code owner September 22, 2025 23:05
@continue continue bot requested review from sestinj and removed request for a team September 22, 2025 23:05
@dosubot dosubot bot added the size:S This PR changes 10-29 lines, ignoring generated files. label Sep 22, 2025
@TyDunn TyDunn requested review from RomneyDa and removed request for sestinj September 22, 2025 23:35
@github-project-automation github-project-automation bot moved this from Todo to In Progress in Issues and PRs Sep 26, 2025
@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Sep 26, 2025
@sestinj sestinj merged commit d006cbd into main Sep 26, 2025
68 of 70 checks passed
@sestinj sestinj deleted the continue-1758582096885 branch September 26, 2025 18:31
@github-project-automation github-project-automation bot moved this from In Progress to Done in Issues and PRs Sep 26, 2025
@github-actions github-actions bot locked and limited conversation to collaborators Sep 26, 2025
@sestinj
Copy link
Contributor

sestinj commented Sep 26, 2025

🎉 This PR is included in version 1.1.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@sestinj
Copy link
Contributor

sestinj commented Sep 26, 2025

🎉 This PR is included in version 1.22.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lgtm This PR has been approved by a maintainer released size:S This PR changes 10-29 lines, ignoring generated files.
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants